﻿using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.IO;
using System.Linq;
using System.Text;
using System.Windows.Forms;
using CopyFolder.Properties;
using Ait = Authorit.API;

namespace CopyFolder
{
    public partial class Progress_Dialog : Form
    {
        public Progress_Dialog()
        {
            InitializeComponent();
        }

        private void LoadProperties()
        {
            Text = Resources.ProgressDialogTitle;
            Icon = Resources.CopyFolderIcon;
        }

        public void UpdateProgressCopy(string objectDescription, int objectId, string objectType)
        {
            lblProgress.Text = String.Format(System.Globalization.CultureInfo.CurrentCulture, Resources.ProgressDialogMessageCopy, objectType, objectDescription, objectId);
            Refresh();
        }

        public void UpdateProgress(string progressMessage)
        {
            lblProgress.Text = progressMessage;
            Refresh();
        }

        public void UpdateProgressReferenceReplace(string objectDescription, int objectId, string objectType)
        {
            lblProgress.Text = string.Format(System.Globalization.CultureInfo.CurrentCulture, Resources.ProgressDialogMessageReplace, objectType, objectDescription, objectId);
            Refresh();
        }

        private void Progress_Dialog_Load(object sender, EventArgs e)
        {
            LoadProperties();
        }
    }
}
